package per.dg.tencent.views.recyclerview;

import android.content.Context;
import android.graphics.Canvas;
import android.graphics.Paint;
import android.graphics.Rect;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;

import androidx.annotation.NonNull;
import androidx.recyclerview.widget.GridLayoutManager;
import androidx.recyclerview.widget.RecyclerView;

import java.util.List;

import per.dg.tencent.R;
import per.dg.tencent.model.VideoModel;

public class SuspensionHeadItemdecoration extends BaseSuspensionHeadItemDecoration<VideoModel> {
    public SuspensionHeadItemdecoration(Context mContext, List<VideoModel> mList) {
        super(mContext, mList);
    }

    @Override
    protected int getSuspensionHeadViewResource() {
        return R.layout.item_title;
    }

    @Override
    public void showView(int showSuspensionHeadPosition, View suspensionHeadView) {
        TextView tv = suspensionHeadView.findViewById(R.id.tv);
        tv.setText(tv.getText()+""+showSuspensionHeadPosition+"");
    }

    @Override
    public boolean is(VideoModel videoModel) {
        if(videoModel.getType().equals("title")){
            return true;
        }
        return false;
    }
}
